<%--
  Created by IntelliJ IDEA.
  User: 周星星
  Date: 2021/10/6
  Time: 14:40
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<html>
<head>
    <title>我的优惠券</title>
    <link href="${pageContext.request.contextPath}/css/coupon/my_coupon.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/css/common.css" rel="stylesheet">
    <link href="http://r1nxp2i0y.hn-bkt.clouddn.com/images/ico.png" rel="icon" type="image/x-ico"/>

    <style>
        .my_coupon_rule_value{
            font-size: 13px;
            float: left;
            margin-top: 20px;
            margin-left: 88px;
            color: #666;
        }
        .couponBtn{
            display: inline-block;
            margin-top: 20px;
        }
        .coupon-step {
            padding: 30px;
            border-top: none;
            margin-top: 50px;
            border-bottom: none;
        }
        .footer {
            width: 100%;
            height: 98px;
            margin-left: 220px;
            position: relative;
            top: -440px;
        }
        .footer-box .footer-right {
            padding: 15px 5px 0 0;
            color: #333;
            width: 480px;
            height: 80px;
            font-size: 0;
            text-align: right;
            float: right;
            position: relative;
            top: 450px;
        }
        .my_coupon_name_value{
            width: 180px;
        }
    </style>
</head>
<body>
<jsp:include page="../message.jsp"/>
<!--=======================================1.标题================================================-->

<jsp:include page="../util/top.jsp"/>
<div class="my_coupon_all">

    <!-------------------------------------------------2.当前位置banner----------------------------------------------->
    <div class="banner">
        <div class="banner_inner">
        <span>当前位置:</span>
        <span class="banner_myCar">我的小橘></span>
        <span>我的优惠编码</span>
        </div>
    </div>
    <!--    侧边栏-->
    <div class="col-sub">
        <dl class="sub-nav">
            <dt>我的订单</dt>
            <dd><a href="${pageContext.request.contextPath}/to_my_order">订单管理</a></dd>
            <dt>我的资产</dt>
            <dd><a>账户余额</a></dd>
            <dd><a href="${pageContext.request.contextPath}/myCoupon/${loginCustomer.custId}">我的优惠券</a></dd>
            <dd><a href="${pageContext.request.contextPath}/favorite/${loginCustomer.custId}">我的收藏</a></dd>
            <dt>个人中心</dt>
            <dd><a href="${pageContext.request.contextPath}/user_center/${loginCustomer.custId}">用户信息</a></dd>
            <dd><a>申请注销账户</a></dd>
        </dl>
    </div>
    <!--=====================================3.优惠券==================================================-->
    <div class="my_coupon">
        <table class="my_coupon_list">
            <tr>
                <th class="my_coupon_name">优惠券</th>
                <th class="my_coupon_get_time">优惠券领取时间</th>
                <th class="my_coupon_invalid_time">优惠卷失效时间</th>
                <th class="my_coupon_status">使用状态</th>
                <th class="my_coupon_rule">使用规则</th>
            </tr>

                <c:forEach var="getCoupon" items="${serverResponse.data}">
            <tr class="couponBtn">
                    <td class="my_coupon_name_value" id="my_coupon_name">${getCoupon.coupon.couponName}</td>
                    <td class="my_coupon_get_time_value">
                            <fmt:formatDate value="${getCoupon.myCoupon.myCouponTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
                    </td>
                    <td class="my_coupon_invalid_time_value">
                            <fmt:formatDate value="${getCoupon.myCoupon.myConuponIneffectiveTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
                    </td>

                        <c:if test="${getCoupon.myCoupon.status==0}">
                            <td class="my_coupon_status_value">未使用</td>
                        </c:if>
                        <c:if test="${getCoupon.myCoupon.status==1}">
                            <td class="my_coupon_status_value">已使用</td>
                        </c:if>
                        <c:if test="${getCoupon.myCoupon.status==2}">
                            <td class="my_coupon_status_value">已过期</td>
                        </c:if>

                    <td class="my_coupon_rule_value">租车满${getCoupon.coupon.couponRuleDay}天可用</td>
            </tr>
                </c:forEach>

        </table>

        <div class="mod coupon-step">
            <h3>使用流程：</h3>
            <p><img src="http://r1nxp2i0y.hn-bkt.clouddn.com/images/coupon_step.png" width="907" height="85" alt="优惠编码使用流程"></p>
        </div>
    </div>
    <!-----------------------------------------------4.footer底部的信息---------------------------------------------------->
    <div class="footer">
        <div class="footer-box clear_float">
            <div class="footer-left">
                <p>
                    <a href="" >关于小橘</a>
                    |
                    <a href="" >移动客户端</a>
                    |
                    <a href="" >帮助中心</a>
                    |
                    <a href="" >建议专区</a>
                    |
                    <a href="" >联系我们</a>
                    |
                    <a href="" >友情链接</a>
                    | &nbsp;投诉通道：400-821-1608 &nbsp;
                </p>
                <p>
                    Copyright © 2007 - 2021 上海小橘信息技术服务有限公司
                    <a href="" >ICP证：沪B2-20140130</a>
                </p>
            </div>
            <div class="footer-right">
                <a href="">
                    <img src="http://r1nxp2i0y.hn-bkt.clouddn.com/images/footer_right_first.png">
                </a>
                <a href="">
                    <img src="http://r1nxp2i0y.hn-bkt.clouddn.com/images/footer_right_second.png">
                </a>
                <a href="">
                    <img src="http://r1nxp2i0y.hn-bkt.clouddn.com/images/footer_right_third.png">
                </a>
                <a href="">
                    <img src="http://r1nxp2i0y.hn-bkt.clouddn.com/images/footer_right_forth.png">
                </a>
            </div>
        </div>
    </div>

</div>

</body>
</html>
